<template>
  <header class="blog-header">
    <div class="container">
      <div class="header-content">
        <div class="logo">
          <img alt="Vue logo" class="logo-img" src="../assets/logo.svg" width="50" height="50" />
          <h1 class="site-title">Android技术博客</h1>
        </div>
        <nav class="nav-menu">
          <ul>
            <li><router-link to="/" class="nav-link" active-class="active">首页</router-link></li>
            <li><router-link to="/original" class="nav-link" active-class="active">VUE</router-link></li>
            <li><router-link to="/apk" class="nav-link" active-class="active">作品</router-link></li>
            <li><a href="#" class="nav-link">文章</a></li>
            <li><a href="#" class="nav-link">关于</a></li>
          </ul>
        </nav>
      </div>
    </div>
  </header>
</template>

<script setup>
// 博客头部组件
</script>

<style scoped>
.blog-header {
  background-color: var(--color-background-soft);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 100;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 15px;
}

.logo-img {
  border-radius: 50%;
}

.site-title {
  font-size: 1.5rem;
  font-weight: 600;
  margin: 0;
  color: var(--color-heading);
}

.nav-menu ul {
  display: flex;
  list-style: none;
  gap: 30px;
}

.nav-link {
  text-decoration: none;
  color: var(--color-text);
  font-weight: 500;
  transition: color 0.3s;
  position: relative;
}

.nav-link:hover {
  color: #42b883;
}

.nav-link.active {
  color: #42b883;
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: #42b883;
}

@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
    gap: 15px;
  }
  
  .nav-menu ul {
    gap: 15px;
  }
}
</style>